﻿<UserControl x:Class="P2.Cuberry.Modules.SimpleSCM.SCProduct.SCProductsFindView"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    Margin="0" MinWidth="230" Width="Auto" MinHeight="230" Height="250">

    <UserControl.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="/P2.Cuberry.Framework.Layout;component/Styles/Styles.xaml"/>     
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>

    </UserControl.Resources>

    <Grid Keyboard.KeyDown="Control_KeyDown">

        <Grid.Resources>
            <Image x:Key="FindIcon" Height="16" Width="16" Source="/P2.Cuberry.Modules.SimpleSCM.SCProduct;component/Images/find16.gif" />
            <Image x:Key="ClearIcon" Height="16" Width="16" Source="/P2.Cuberry.Modules.SimpleSCM.SCProduct;component/Images/clear.png" />
            <Image x:Key="AddIcon" Height="16" Width="16" Source="/P2.Cuberry.Modules.SimpleSCM.SCProduct;component/Images/add.png" />
        </Grid.Resources>

        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="*"/>
        </Grid.ColumnDefinitions>

        <Grid.RowDefinitions>
            <RowDefinition Height="28"/>
            <RowDefinition Height="4" />
            <RowDefinition Height="*"/>
            <RowDefinition Height="2" />
        </Grid.RowDefinitions>


        <Menu Grid.Column="0" Grid.Row="0" x:Name="menuMain" Height="25" VerticalAlignment="Top" Background="{DynamicResource MyBlueBackgroundGradientBrush}" >
            <MenuItem x:Name="btnSCProductFind" Margin="2,4,0,2"  Header="{Translate SCProductFind}" x:Uid="btnSCProductFind" Command="{Binding SCProductFindCommand}" Icon="{StaticResource FindIcon}" Style="{StaticResource P2FindMenuItemStyle}"/>            
            <MenuItem x:Name="btnSCProductClr" Margin="2,4,0,2"  Header="{Translate SCProductClr}" x:Uid="btnSCProductClr" Command="{Binding SCProductClrCommand}"  Icon="{StaticResource ClearIcon}" Style="{StaticResource P2FindMenuItemStyle}"/>            
            <MenuItem x:Name="btnSCProductAdd" Margin="2,4,0,2"   Header="{Translate SCProductAdd}" x:Uid="btnSCProductAdd" Command="{Binding SCProductAddCommand}"  Icon="{StaticResource AddIcon}" Style="{StaticResource P2FindMenuItemStyle}"/>
        </Menu>
        
        <Label Grid.Row="2" Height="23" Margin="1,25,0,0" Name="ProductNameEnL"  VerticalAlignment="Top" HorizontalAlignment="Left" Width="86" Tag="SxL" Content="{Translate ProductNameEnL}"></Label>
        <TextBox Grid.Row="2" Height="23" Margin="90,25,8,0" Name="ProductNameEn"  Text="{Binding Model.ProductNameEn}" VerticalAlignment="Top" Tag="SxText" Style="{StaticResource P2TextBoxStyle}" />
       
        <Label Grid.Row="2" Height="23" Margin="1,140,0,0" Name="StatusNameL" HorizontalAlignment="Left" Width="86" Tag="SxL" VerticalAlignment="Top"  Content="{Translate StatusNameL}"></Label>
        <ComboBox Grid.Row="2" Height="23" Margin="102,0,9,53" Name="StatusID" VerticalAlignment="Bottom" SelectedValuePath="StatusID" DisplayMemberPath="StatusNameCur" Style="{StaticResource P2ComboBoxStyle}" />
        <Label Content="{Translate ProductCategoryIDL}" Height="27.723" HorizontalAlignment="Left" Margin="1,61,0,0" Name="ProductCategoryIDL" VerticalAlignment="Top" Width="126" Grid.Row="2" />
        <ComboBox DisplayMemberPath="CategoryNameCur" Grid.Row="2" Height="23.722" IsEnabled="{Binding IsEditable}" ItemsSource="{Binding ProductCategorys}" Margin="102,61,12,0" Name="ProductCategoryID" SelectedValue="{Binding ProductCategoryID, ValidatesOnExceptions=True, NotifyOnValidationError=True, ValidatesOnDataErrors=True}" SelectedValuePath="ProductCategoryID" Style="{StaticResource P2ComboBoxStyle}" Validation.ErrorTemplate="{StaticResource ErrorTemplate}" VerticalAlignment="Top" />
        <Label Content="{Translate ProductTypeIDL}" Grid.Row="2" HorizontalAlignment="Left" Margin="1,96,0,92" Name="ProductTypeIDL" Width="106" />
        <ComboBox DisplayMemberPath="ProductTypeCur" Grid.Row="2" IsEnabled="{Binding IsEditable}" ItemsSource="{Binding ProductTypes}" Margin="102,96,12.373,96" Name="ProductTypeID" SelectedValue="{Binding ProductTypeID, ValidatesOnExceptions=True, NotifyOnValidationError=True, ValidatesOnDataErrors=True}" SelectedValuePath="ProductTypeID" Style="{StaticResource P2ComboBoxStyle}" Validation.ErrorTemplate="{StaticResource ErrorTemplate}" />
    </Grid>
</UserControl>
